<template>
    <a-radio-group name="radioGroup" :default-value="1" @change="radioChange">
        <a-radio :value="1">
            全部{{title}}({{allLength}})
        </a-radio>
        <a-radio :value="2">
            结余{{title}}({{surplusLength}})
        </a-radio>
        <a-radio :value="3">
            超支{{title}}({{overspendLength}})
        </a-radio>
    </a-radio-group>
</template>

<script>
    export default {
        name: "radioGroup",
        props: {
            allLength:Number,
            surplusLength:Number,
            overspendLength:Number,
            title:String,
        },
        watch:{
            departmentData:val => {
                console.log(val);
            }
        },
        data() {
            return {

            }
        },
        created(){

        },
        mounted () {

        },
        methods: {
            radioChange(e){
                this.$emit('listChange',e.target.value)
            }
        }
    }
</script>

<style  lang="stylus" scoped>

</style>
